define([ "dojo/_base/declare","esri/renderers/Renderer","esri/symbols/SimpleFillSymbol",
         "esri/symbols/SimpleLineSymbol","esri/Color"],
    function(declare,Renderer,SimpleFillSymbol,SimpleLineSymbol,Color) {
        return declare([Renderer], {
        	map:null,
            constructor : function(args) {
            	this.map=args;
            	dojo.mixin(this,arguments[0]);
            },
            config:null,
        	getSymbol:function(graphic){
        		var symbol = this.getSymbolFromColor(this.config.color);
        		return symbol;
        	},
        	getSymbolFromColor:function(color){
        		var color = color.substring(color.indexOf("[")+1, color.indexOf("]"));
        		var colorArr=color.split(",");
	        	var line=new SimpleLineSymbol(SimpleLineSymbol.STYLE_SOLID, new dojo.Color([255,255,255,0.3]), 1);
				var symbol=new SimpleFillSymbol(SimpleFillSymbol.STYLE_SOLID,line,new dojo.Color([parseInt(colorArr[0]),parseInt(colorArr[1]),parseInt(colorArr[2]),parseFloat(colorArr[3])]));
				return symbol;
        	}
        });
    });